﻿using System;
using System.Collections.Generic;
using Neits.Common;
using Neits.UserService;

namespace Projecturo.Model
{
    public class Project : IInstanceIdentifier, IHasDataContext, ICreated, IChanged, IName, IDescription
    {
        private IList<Ticket> tickets = new List<Ticket>();
        private IList<Milestone> milestones = new List<Milestone>();

        public virtual long Id { get; set; }
        public virtual string Name { get; set; }
        public virtual string Description { get; set; }
        public virtual IList<Ticket> Tickets
        {
            get { return tickets; }
            set { tickets = value; }
        }

        public virtual IDataContext DataContext { get; set; }

        public virtual DateTime CreateDate { get; set; }
        public virtual IUser CreatedBy { get; set; }

        public virtual DateTime ChangeDate { get; set; }
        public virtual IUser ChangedBy { get; set; }

        public virtual IList<Milestone> Milestones
        {
            get { return milestones; }
            set { milestones = value; }
        }

        public virtual TicketState DefaultTicketState { get; set; }
    }
}
